public class test12 {
    public static void main(String[] args) {
        int a =1234;
        int temp=a;
        int num=0;
        while(a!=0){
            int x=a%10;
            a=a/10;
            num = num*10+x;
        }
        System.out.println(num);
        System.out.println(num == temp);
    }
}
